#include<stdio.h>
#define my_offsetof(type,name) (int)&(((type*)0)->name)
struct test
{
	char c1;
	int i;
	char c2;
};
int main()
{
	printf("%d\n",my_offsetof(struct test,c2));
	return 0;
}
